package com.xinhe.web.controller;

import com.xinhe.web.entity.AdapayBank;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.validation.Valid;
@RestController
@RequestMapping(value = "/adapayBank")
@Api(value = "adapay银行", tags = "adapay银行")
public class AdapayBankController {

    /*@Autowired
    private IAdapayBankService adapayBankService;
    @ApiOperation(httpMethod = "GET", value = "分页查询adapay银行")
    @RequestMapping({"/pageAdapayBank"})
    public PageResult<AdapayBankView> pageAdapayBank(AdapayBankQuery query) {
        return this.adapayBankService.pageAdapayBank(query);
    }
    @ApiOperation(httpMethod = "POST", value = "保存adapay银行")
    @RequestMapping({"/saveAdapayBank"})
    public BaseResult saveAdapayBank(@Valid AdapayBankModel model, BindingResult bind) {
        if (bind.hasErrors()) {
            BaseResult result = new BaseResult();
            result.setBindingResult(bind);
            return result;
        }
        return (BaseResult)this.adapayBankService.saveModel((IdModel)model);
    }
    @ApiOperation(httpMethod = "GET", value = "删除adapay银行")
    @ApiImplicitParam(name = "adapayBankId", value = "标识", dataTypeClass = Long.class, required = true)
    @RequestMapping({"/deleteAdapayBank"})
    public BaseResult deleteAdapayBank(Long adapayBankId) {
        return this.adapayBankService.delete(adapayBankId);
    }
    @ApiOperation(httpMethod = "GET", value = "adapay银行详情")
    @ApiImplicitParam(name = "adapayBankId", value = "标识", dataTypeClass = Long.class, required = true)
    @RequestMapping({"/detailAdapayBank"})
    public BeanResult<AdapayBank> detailAdapayBank(Long adapayBankId) {
        return this.adapayBankService.findById(adapayBankId);
    }*/
}